import { createRouter, createWebHistory } from "vue-router";
import bpmnJsView from "@/views/bpmnJs";
import flowView from "@/views/flow";
import Layout from "@/layout";

const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path: "/",
      redirect: "/bpmn-js",
    },
    {
      path: "/bpmn-js",
      name: "bpmnJsView",
      component: Layout,
      hidden: false,
      children: [
        {
          path: "/bpmn-js",
          component: bpmnJsView,
        },
      ],
    },
    {
      path: "/flow",
      name: "flowView",
      component: Layout,
      hidden: false,
      children: [
        {
          path: "/flow",
          component: flowView,
        },
      ],
    },
  ],
});

export default router;
